window.onload = function() {

	oText = document.getElementsByTagName('input')[0];
	oUl = document.getElementsByTagName('ul')[0];

	oText.onkeydown = function(ev) {
		ev = ev || event;
		if(this.value !== '') {
			if(ev.keyCode == 13 && ev.ctrlKey) {
				var oLi = document.createElement('li');
				oLi.innerHTML = this.value;
				if(oUl.children[0]) {
					oUl.insertBefore(oLi, oUl.children[0]);
				} else {
					oUl.appendChild(oLi);
				}
				this.value = '';
			}
		}
	};

};

var oText = null;
var oUl = null;
